<script setup lang="ts">
import { ref } from "vue";
import { useRole } from "./utils/hook";

defineOptions({
  name: "ZjyctjMonth"
});
const formRef = ref();
const { loading, columns, dataList, onSearch, sendMail } = useRole();
</script>

<template>
  <div class="main">
    <el-form
      ref="formRef"
      :inline="true"
      class="search-form bg-bg_color w-[99/100] pl-8 pt-[12px]"
    >
      <el-form-item>
        <el-button type="primary" :loading="loading" @click="onSearch">
          搜索
        </el-button>
        <el-button @click="sendMail()"> 发送邮件 </el-button>
      </el-form-item>
    </el-form>
    <pure-table :data="dataList" :columns="columns" border />
  </div>
</template>

<style scoped lang="scss">
:deep(.el-dropdown-menu__item i) {
  margin: 0;
}

.search-form {
  :deep(.el-form-item) {
    margin-bottom: 12px;
  }
}
</style>
